"distroless"

module(name = "distroless")

bazel_dep(name = "bazel_skylib", version = "1.8.1")
bazel_dep(name = "aspect_bazel_lib", version = "2.21.1")
bazel_dep(name = "platforms", version = "1.0.0")
bazel_dep(name = "rules_go", version = "0.57.0")
bazel_dep(name = "gazelle", version = "0.38.0")
bazel_dep(name = "rules_pkg", version = "1.1.0")
bazel_dep(name = "rules_rust", version = "0.63.0")
bazel_dep(name = "container_structure_test", version = "1.19.1")
bazel_dep(name = "rules_oci", version = "1.8.0")
bazel_dep(name = "rules_distroless", version = "0.5.3")
bazel_dep(name = "rules_python", version = "1.5.3")
bazel_dep(name = "rules_cc", version = "0.2.0")

### OCI ###
oci = use_extension("@rules_oci//oci:extensions.bzl", "oci")
oci.toolchains(crane_version = "v0.18.0")
use_repo(oci, "oci_crane_toolchains")

### PYTHON ###
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
python.toolchain(
    ignore_root_user_error = True,
    python_version = "3.11",
)

### GO ####
go_deps = use_extension("@gazelle//:extensions.bzl", "go_deps")
go_deps.module(
    path = "github.com/spdx/tools-golang",
    sum = "h1:9B623Cfs+mclYK6dsae7gLSwuIBHvlgmEup87qpqsAQ=",
    version = "v0.3.1-0.20230104082527-d6f58551be3f",
)
use_repo(go_deps, "com_github_spdx_tools_golang")

### BUSYBOX ###
busybox = use_extension("//private/extensions:busybox.bzl", "busybox")
busybox.archive()
use_repo(busybox, "busybox_amd64", "busybox_arm", "busybox_arm64", "busybox_ppc64le", "busybox_s390x")

### JAVA ###
include("//private/repos/java_temurin:java.MODULE.bazel")

### NODE ###
node = use_extension("//private/extensions:node.bzl", "node")
node.archive()
use_repo(node, "nodejs20_amd64", "nodejs20_arm", "nodejs20_arm64", "nodejs20_ppc64le", "nodejs20_s390x", "nodejs22_amd64", "nodejs22_arm", "nodejs22_arm64", "nodejs22_ppc64le", "nodejs22_s390x", "nodejs24_amd64", "nodejs24_arm64", "nodejs24_ppc64le", "nodejs24_s390x")

### DEBIAN ###
include("//private/repos/deb:deb.MODULE.bazel")
